<template>
  <basic-container>
    <distribution-statement-list
      v-show="showType === 'list'"
      @openDistributionStatementDetail="openDistributionStatementDetail"
    ></distribution-statement-list>
    <distribution-statement-detail
      :detail="detail"
      v-if="showType === 'detail'"
      @back="handleBack"
    ></distribution-statement-detail>
  </basic-container>
</template>

<script>
import distributionStatementList from "@/views/financial/distribution-statement-list.vue";
import distributionStatementDetail from "@/views/financial/distribution-statement-detail.vue";
export default {
  data() {
    return {
      showType: "list",
      detail: {},
    };
  },
  components: {
    distributionStatementList,
    distributionStatementDetail,
  },
  computed: {},
  methods: {
    handleBack() {
      this.showType = "list";
    },
    openDistributionStatementDetail(detail) {
      this.showType = "detail";
      this.detail = detail;
    },
  },
};
</script>

<!--<style scoped>-->
<!--</style>-->
